package com.xiaoxi.open.common.util;


import com.xiaoxi.open.common.constant.RegularConstants;

/**
 * @Author xiaoxi
 * @ProjectName bms
 * @PackageName com.xiaoxi.bms.common.util
 * @ClassName RegularUtils
 * @Description TODO
 * @Date 2023/6/5 14:16
 * @Version 1.0
 */
public class RegularUtils {

    public static boolean passwordRegular(String password) {
        return password.matches(RegularConstants.REGULAR_PASSWORD_COMPLEXITY);
    }

    public static boolean ipv4Regular(String ip) {
        return ip.matches(RegularConstants.REGULAR_IPV4);
    }

    public static boolean ipv6Regular(String ip) {
        return ip.matches(RegularConstants.REGULAR_IPV6);
    }

}
